using UnityEngine;
using System.Collections;

public class InitPartner : MonoBehaviour {
	
	public GameObject item;
	
	//Get partner's count
	int count = 0;
	
	// Use this for initialization
	void Awake () {
		Init();
	}
	
	void Init(){
		for(int i = 0; i < count;i++){
			GameObject buttonItem = (GameObject)Instantiate(item);
			
			buttonItem.transform.parent = transform;
			buttonItem.transform.localScale = Vector3.one;
			buttonItem.name += "_" + i;
			
			Transform trans= buttonItem.transform.FindChild("LV");
			UILabel nameLabel = trans.GetComponent<UILabel>();
			nameLabel.text = i + "";
			
			UICheckbox checkBox = buttonItem.GetComponent<UICheckbox>();
			checkBox.startsChecked = false;
			
			SendPartnerInfo partnerInfo = buttonItem.GetComponent<SendPartnerInfo>();
			partnerInfo.partnerId = i;
		}
	}
}
